<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>用户列表</title>
<hdjs/>
</head>
<body>
	<div class="wrap">
		<div class="title-header">用户列表</div>
		<table class="table1">
			<tr>
				<td>UID</td>
				<td>用户名</td>
				<td>角色</td>
				<td>状态</td>
				<td>注册时间</td>
				<td>操作</td>
			</tr>
			<list from="$user" name='$u'>
			<tr>
				<td>{$u.uid}</td>
				<td>{$u.username}</td>
				<td>{$u.role_name}</td>
				<if value="{$u.status} eq 1">
					<td class="ok"><span class="status" status='1' uid="{$u.uid}">正常</span></td>
				<else>
					<td class="lock"><span class="status" status='0' uid="{$u.uid}">锁定</span></td>
				</if>	
				<td>{$u.addtime|date:'Y-m-d',@@}</td>
				<td>
					<a href="{|U:'edit',array('uid'=>$u['uid'])}">编辑</a>
					<a href="{|U:'edit',array('uid'=>$u['uid'])}">删除</a>
				</td>
			</tr>
			</list>
		</table>
	</div>
	<style type="text/css">
		.status{cursor: pointer;}
		table.table1 tr .ok{color: green;}
		table.table1 tr .lock{color: red;}
	</style>
	<js file="__CONTROLLER_VIEW__/js/index.js"/>
</body>
</html>